package es.ignapziriza.ccrypto;

/**
 * Abstract class for those algorithms where the ciphering must have a keyword.
 * 
 * @author ignapziriza
 * 
 */
public abstract class CipheredText {
	protected String keyword;
	protected String cipheredText;

	/**
	 * Gets the keyword.
	 * 
	 * @return the keyword set on the algorithm.
	 * @throws KeyWordNotSetException
	 *             if there isn't a keyword set yet.
	 * 
	 * @author ignapziriza
	 */
	public String getKeyword() throws KeyWordNotSetException {
		return keyword;
	}

	/**
	 * Sets the keyword.
	 * 
	 * @param keyword
	 *            the keyword to set.
	 * 
	 * @author ignapziriza
	 */
	public void setKeyword(String keyword) {
		this.keyword = keyword;
	}

	/**
	 * Gets the ciphered text.
	 * 
	 * @return the ciphered text.
	 * 
	 * @author ignapziriza
	 */
	public String getCipheredText() {
		return cipheredText;
	}

	/**
	 * Sets the new ciphered text.
	 * 
	 * @param cipheredText
	 *            the new ciphered text.
	 * 
	 * @author ignapziriza
	 */
	public void setCipheredText(String cipheredText) {
		this.cipheredText = cipheredText;
	}
}
